package linkedlistdemo;

public class Test {
    public static void main(String[] args) {
        MyLinkedList myLinkedList = new MyLinkedList();
        myLinkedList.addLast(1);
        myLinkedList.addLast(2);
        myLinkedList.addLast(3);
        myLinkedList.addLast(4);
        myLinkedList.display();
        System.out.println("==============");
        myLinkedList.addIndex(0,99);
        myLinkedList.addIndex(2,2);
        myLinkedList.addIndex(6,99);
        myLinkedList.display();
        System.out.println("==============");
        System.out.println(myLinkedList.contains(-1));
        myLinkedList.removeAllKey(2);
        myLinkedList.display();


    }
    public static void main1(String[] args) {
        MyLinkedList myLinkedList = new MyLinkedList();
        myLinkedList.addFirst(1);
        myLinkedList.addFirst(2);
        myLinkedList.addFirst(3);
        myLinkedList.addFirst(4);
        myLinkedList.display();
    }
}
